<?php
// +----------------------------------------------------------------------
// | author: admin
// +----------------------------------------------------------------------

namespace app\adminapi\validate\travel;


use app\common\validate\BaseValidate;


/**
 * Line验证器
 * Class LineValidate
 * @package app\adminapi\validate\travel
 */
class LineValidate extends BaseValidate
{

     /**
      * 设置校验规则
      * @var string[]
      */
    protected $rule = [
        'id' => 'require',
        'travel_agency_id' => 'require',
        'title' => 'require',
        'start_address' => 'require',
        'end_address' => 'require',
        'line_image' => 'require',

    ];


    /**
     * 参数描述
     * @var string[]
     */
    protected $field = [
        'id' => 'id',
        'travel_agency_id' => '旅行社ID',
        'title' => '线路名称',
        'start_address' => '出发地点',
        'end_address' => '到达地点',
        'line_image' => '线路图片',
    ];


    /**
     * @notes 添加场景
     * @return LineValidate
     * @author admin
     * @date 2025/04/25 10:24
     */
    public function sceneAdd()
    {
        return $this->only(['travel_agency_id','title','start_address','end_address','line_image']);
    }


    /**
     * @notes 编辑场景
     * @return LineValidate
     * @author admin
     * @date 2025/04/25 10:24
     */
    public function sceneEdit()
    {
        return $this->only(['id','travel_agency_id','title','start_address','end_address','line_image']);
    }


    /**
     * @notes 删除场景
     * @return LineValidate
     * @author admin
     * @date 2025/04/25 10:24
     */
    public function sceneDelete()
    {
        return $this->only(['id']);
    }


    /**
     * @notes 详情场景
     * @return LineValidate
     * @author admin
     * @date 2025/04/25 10:24
     */
    public function sceneDetail()
    {
        return $this->only(['id']);
    }

    /**
     * @notes  更改状态场景
     * @return LineValidate
     */
    public function sceneStatus()
    {
        return $this->only(['id', 'status']);
    }


}